#include <iostream>
#include <iomanip>
#include <string>
using namespace std;
int main() {
    int n; 
    cin >> n; 
    for (int i = 0; i < n; i++) {
        string name;
        double chinese, math, english;
        cin >> name >> chinese >> math >> english; 
        double average = (chinese + math + english) / 3; 
        cout << fixed << setprecision(2);
        cout << name << " " << setw(6) << chinese << " " << setw(6) << math << " " << setw(6) << english << " " << setw(6) << average; 
        if (average >= 90) 
		{ 
            cout << " Excellent"; 
        }
        cout << endl; 
    }
    return 0;
}